<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    // switch   1 2 3 4  case
    let money = 100000

    while (true) {
      let cz = prompt(`
      请输入您的操作：
      1.存钱
      2.取钱
      3.查看余额
      4.退出
      `)
      switch (cz) {
        case '1':
          let cq = +prompt('请输入您存的数额')
          money = money + cq
          break
          case '2':
          let qq = +prompt('请输入您取的数额')
          money = money - qq
          break
          case '3':
          let shenyu = +prompt(`你还剩${money}`)
          alert(money)
          break
          
      }
      if (cz === '4'){
        alert('退出成功')
      break
      }
      
    }

  </script>
</body>
</html>